package at.fhooe.engine.event.events;

import at.fhooe.engine.event.EventListener;

public class MapObjectDestroyedEvent extends Event{

	public static final String TYPE = "MapObjectDestroyed";
	private String m_mapObjectId;
	private String m_mapObjectName;
	
	public MapObjectDestroyedEvent(String mapObjectId, String mapObjectName) {
		super(TYPE);
		m_mapObjectId = mapObjectId;
		m_mapObjectName = mapObjectName;
	}

	public String getMapObjectId() {
		return m_mapObjectId;
	}

	public String getMapObjectName() {
		return m_mapObjectName;
	}

	@Override
	public void processEvent(EventListener eventListener) {
		((Listener) eventListener).onMapObjectDestroyedEvent(this);
	}

	//embedded listener interface with the specific function call
	public interface Listener extends EventListener {
		public void onMapObjectDestroyedEvent(MapObjectDestroyedEvent mapObjectDestroyedEvent);
	}
}
